package com.example.emos.wx.db.mapper;

import com.example.emos.wx.db.pojo.TbRole;
import org.apache.ibatis.annotations.Mapper;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

/**
* @author ShowTimE
* @description 针对表【tb_role(角色表)】的数据库操作Mapper
* @Entity com.example.emos.wx.db.pojo.TbRole
*/
@Mapper
public interface TbRoleMapper {

    ArrayList<HashMap> searchRoleOwnPermission(Integer roleId);

    Integer insertRole(TbRole role);

    Integer updateRolePermission(TbRole role);

    ArrayList<HashMap> searchAllPermission();

    List<TbRole> searchAllRole();

    long searchRoleUsersCount(Integer id);

    Integer deleteRoleById(Integer id);

}
